package com.hopu.oa.service.UserManageService;


import com.hopu.oa.entity.user.AoaDept;
import com.hopu.oa.entity.user.AoaPosition;
import com.hopu.oa.entity.user.AoaUser;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface DeptManageService {
    /**
     * 分页页面展示
     */
    List<AoaDept> findAllDepts();


    List<AoaDept> findAllDept(String deptName, @Param("index") int index, @Param("size") int size);

    AoaDept findDeptById(int id);

    AoaDept findDeptByDeptName(String deptName);

    int insertDept(String deptName, String deptTel, String deptFax, String email, String deptAddr, String startTime, String endTime);

    int updateDept(String deptName, String deptTel, String deptFax, String email, String deptAddr, String endTime, int deptId);

    List<AoaUser> findAllUserByDeptId(int deptId);

    int deleteDept(int deptId);

    int findDeptByDeptNameId(String deptName);

    List<AoaDept> findDept();

    /**
     * 人事调动
     *
     * @return
     */
    List<AoaDept> selectDepts();

    List<AoaUser> selectUserBydeptId(int deptid);

    AoaUser selectRelaName(int deptid);

    AoaDept selectDeptById(int deptid);

    List<AoaPosition> selectPositionById(int deptid);

    List<AoaDept> selectdeptAll();

    int updatePositionById(int userid, int positionid, int deptid);

    int updateDeptmanager(int juserid, int deptid);
}
